package com.pictures;

import android.graphics.drawable.AnimationDrawable;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
import android.view.animation.Animation;
import android.view.animation.AnimationUtils;
import android.widget.ImageView;


public class MainActivity extends AppCompatActivity {
    ImageView imageView;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);

        setContentView(R.layout.activity_main);
        imageView = (ImageView) findViewById(R.id.img);
    }

    public void alpha(View view){
        Animation animation = AnimationUtils.loadAnimation(this,R.anim.alpha);
        imageView.startAnimation(animation);
    }
    public void rotate(View view){
        Animation animation = AnimationUtils.loadAnimation(this,R.anim.rotate);
        imageView.startAnimation(animation);
    }
    public void scale(View view){
        Animation animation = AnimationUtils.loadAnimation(this,R.anim.scale);
        imageView.startAnimation(animation);
    }
    public void move(View view){
        Animation animation = AnimationUtils.loadAnimation(this,R.anim.move);
        imageView.startAnimation(animation);
    }
}
